unit add_mark_unit;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics,
  Controls, Forms, Dialogs, data_module, cxGraphics, cxControls,
  cxLookAndFeels, cxLookAndFeelPainters, cxContainer, cxEdit, dxSkinsCore,
  dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee,
  dxSkinDarkRoom, dxSkinDarkSide, dxSkinDevExpressDarkStyle,
  dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast,
  dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky,
  dxSkinMcSkin, dxSkinMoneyTwins, dxSkinOffice2007Black, dxSkinOffice2007Blue,
  dxSkinOffice2007Green, dxSkinOffice2007Pink, dxSkinOffice2007Silver,
  dxSkinOffice2010Black, dxSkinOffice2010Blue, dxSkinOffice2010Silver,
  dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
  dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
  dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine, dxSkinVS2010,
  dxSkinWhiteprint, dxSkinXmas2008Blue, ImgList, cxDBLookupComboBox,
  cxTextEdit, cxMaskEdit, cxDropDownEdit, cxLookupEdit, cxDBLookupEdit,
  StdCtrls, marks_edit_unit, cxSpinEdit, cxDBEdit;

type
  Tadd_mark_form = class(TForm)
    Label3: TLabel;
    Label4: TLabel;
    ok_button: TButton;
    cancek_button: TButton;
    ImageList1: TImageList;
    study_plan_combo: TcxDBLookupComboBox;
    Label2: TLabel;
    cxDBTextEdit1: TcxDBTextEdit;
    cxDBTextEdit2: TcxDBTextEdit;
    cxDBTextEdit3: TcxDBTextEdit;
    Label1: TLabel;
    Label5: TLabel;
    cxDBTextEdit4: TcxDBTextEdit;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  add_mark_form: Tadd_mark_form;

implementation

{$R *.dfm}

procedure Tadd_mark_form.Button1Click(Sender: TObject);
begin
  if marks_edit_form.ShowModal=mrOK then
  begin
    data_mod.sql_connection.Commit;
    data_mod.sql_connection.StartTransaction;
  end else begin
    data_mod.sql_connection.Rollback;
    data_mod.sql_connection.StartTransaction;
  end;
end;

end.
